<template>
<div>
	<hr>
	<el-button @click='fn1'>111</el-button>
    <ProvideInject11 />
</div>
</template>
<script>
import { ref, provide } from 'vue'
import ProvideInject11 from '/@/compositionAPI/message/ProvideInject11.vue'

export default {
	name: 'ProvideInject1',
	components: {
		ProvideInject11,
	},
	setup (props, context) {
		const color = ref('red');
		provide('color', color);
		const fn1 = () => {
			console.log(11);
			color.value = 'red2';
		};
		return {
			color,
			fn1,
		}
	},
}
</script>
<!-- Add "scoped" attribute to limit CSS to this component only -->
<style scoped>
</style>